﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.ComponentModel.DataAnnotations;
using System.Data.Entity.ModelConfiguration;

namespace DataModel
{
    public class Settings
    {
        [Column("ID")]
        public string ID { get; set;  }
        [Column("IDVALUE")]
        public string Value { get; set; }
        [Column("DESCRIPTION")]
        public string Description { get; set; }
    }

    public class SettingsConfiguration : EntityTypeConfiguration<Settings>
    {
        public SettingsConfiguration()
        {
            HasKey(x => x.ID);
            Property(x => x.ID).HasDatabaseGeneratedOption(DatabaseGeneratedOption.None);
            Property(x => x.Value).IsRequired();
            ToTable("SETTINGS");
        }
    }
}
